﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Practices.Prism.Modularity;
using Microsoft.Practices.Unity;
using Microsoft.Practices.Prism.Regions;
using compshop.Modules.ListOfSuppliers.View;
using compshop.Infrastructure;

namespace compshop.Modules.ListOfSuppliers
{
  public  class SuppliersListModule: IModule
    {
        IUnityContainer container; 
        IRegionManager regionManager;

        public SuppliersListModule(IUnityContainer Container, IRegionManager RegionManager)
        {
            container = Container;
            regionManager = RegionManager;
        }

        public void Initialize()
        { 
          //  container.RegisterType():
            regionManager.Regions[RegionNames.SuppliersContent].Add(container.Resolve<SuppliersListView>());
        }
    }
}
